<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>点击我</title>
    <script src="../js/jquery-2.1.1.js"></script>
    <script>
        $(document).ready(function(){
            $("#click").click(function(){
            alert("click one time");
            });
            $("#click").click(function(){
            alert("click two time");
            });
            var days = ['日','一','二','三','四','五','六'];
            var date = new Date();

            console.log('今天是星期' + days[date.getDay()]);
            for (var i = 0; i < 5; ++i) {
                setTimeout(function () {
                    console.log(i + ' ');
                }, 100);
            }
            for (var i = 0; i < 5; ++i) {
                (function (i) {
                    setTimeout(function () {
                        console.log(i + ' ');
                    }, 100);
                }(i));
            }

        });
    </script>
</head>
<body>
     <input type="button" id="click"value="点击我"/>
</body>
</html>